import request from '@/utils/request'

// 查询C端用户license列表
export function listLicense(query) {
  return request({
    url: '/system/license/list',
    method: 'get',
    params: query
  })
}

// 查询C端用户license详细
export function getLicense(id) {
  return request({
    url: '/system/license/' + id,
    method: 'get'
  })
}

// 新增C端用户license
export function addLicense(data) {
  return request({
    url: '/system/license',
    method: 'post',
    data: data
  })
}

// 修改C端用户license
export function updateLicense(data) {
  return request({
    url: '/system/license',
    method: 'put',
    data: data
  })
}

// 删除C端用户license
export function delLicense(id) {
  return request({
    url: '/system/license/' + id,
    method: 'delete'
  })
}

// 修改C端用户license
export function verifyLicense(params) {
  return request({
    url: '/system/license/verify',
    method: 'get',
    params: params
  })
}

// 修改C端用户license
export function verifyExtendLicense(params) {
  return request({
    url: '/system/license/verifyExtend',
    method: 'get',
    params: params
  })
}

// 修改C端用户license
export function cancelLicense(params) {
  return request({
    url: '/system/license/cancel',
    method: 'get',
    params: params
  })
}
